#ifndef __SPACEDEFENDER_LogWriter_H__
#define __SPACEDEFENDER_LogWriter_H__

#include <string>
#include <fstream>
#include "observer.h"

namespace spacedefender
{

class Subject;

class LogWriter : public Observer
{
	public:
		LogWriter(std::string fileName);
		LogWriter(std::string fileName, bool clearFile);
		~LogWriter();
		
		virtual void Notification(const Subject* sender);
	private:
		virtual void Init(std::string fileName, bool clearFile);
	
		std::string _fileName;
		std::ofstream _logFile;
};

}
#endif __SPACEDEFENDER_LogWriter_H__
